/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: dings
 * Date: 2024-05-11
 * Time: 13:19
 */
class Student {
    public String name = "丁";
    public int age = 18;
    public String sex = "男";
    public Student() {
        this("dings",18,"男");
        System.out.println("不带参数的构造方法");
    }
    public Student(String name, int age, String sex) {
        this.name = name;
        this.age = age;
        this.sex = sex;
    }

    public void setData(String name, int age, String sex) {
        this.name = name;
        this.age = age;
        this.sex = sex;
    }
}
public class Test {

    public static void test() {
        int number;
        System.out.println(number);
    }


    public static void main(String[] args) {
        Student student1 = new Student();
        student1.setData("dings",18,"男");
       /* System.out.println(student1.name);
        System.out.println(student1.age);
        System.out.println(student1.sex);*/


        Student student2 = new Student();
        Student student3 = new Student();
        Student student4 = new Student();



       /* System.out.println(student1.name);
        System.out.println(student1.age);
        System.out.println(student1.sex);
        student1.study();*/
    }
}
